<?php

namespace App\Kuafu\Order\Validate;

use App\Kuafu\Order\Enum\OrderCodeEnum;
use App\Kuafu\Order\Exceptions\OrderException;
use App\Kuafu\Order\Model\OrderSplitModel;
use App\Kuafu\Shop\Service\ShopService;
use App\Kuafu\Base\Validate\BaseValidate;
use Illuminate\Http\Request;

class OrderStatisticsValidate extends BaseValidate
{
    public static function productSaleStatistics(Request $request)
    {
        $rules    = [
            'shopId'  => 'required',
            'startAt' => 'required',
            'endAt'   => 'required',
            'source'  => 'required',
        ];
        $messages = [
            'shopId.required'  => '请选择店铺',
            'startAt.required' => '请选择开始时间',
            'endAt.required'   => '请选择结束时间',
            'source.required'  => '请选择订单来源',
        ];
        return self::validateCheck($request->all(), $rules, $messages);
    }

}
